package com.ln.adoms.entity;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.ln.core.orm.hibernate.BaseEntity;

@Entity
@Table(name = "Order_marchandise_detail")
public class OrderMarchandiseDetail extends BaseEntity {

	private Double costSummary;// 商品总价

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "marchandise_id")
	private Marchandise marchandise;// 订购商品

	private Integer number; // 商品数量

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "order_id")
	private Order order; // 所属订单

	private Double unitPrice; // 商品单价

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "brand_id")
	private Brand brand; // 品牌

	private String memo; // 备注

	public Double getCostSummary() {
		return costSummary;
	}

	public void setCostSummary(Double costSummary) {
		this.costSummary = costSummary;
	}

	public Marchandise getMarchandise() {
		return marchandise;
	}

	public void setMarchandise(Marchandise marchandise) {
		this.marchandise = marchandise;
	}

	public Integer getNumber() {
		return number;
	}

	public void setNumber(Integer number) {
		this.number = number;
	}

	public Order getOrder() {
		return order;
	}

	public void setOrder(Order order) {
		this.order = order;
	}

	public Double getUnitPrice() {
		return unitPrice;
	}

	public void setUnitPrice(Double unitPrice) {
		this.unitPrice = unitPrice;
	}

	public Brand getBrand() {
		return brand;
	}

	public void setBrand(Brand brand) {
		this.brand = brand;
	}

	public String getMemo() {
		return memo;
	}

	public void setMemo(String memo) {
		this.memo = memo;
	}

}